package com.sleepfish.generator.mapper;


import com.sleepfish.generator.domain.BpmForm;
import com.sleepfish.generator.domain.VO.form.BpmFormPageReqVO;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Update;


import java.util.List;

/**
 * @author fumingchao
 * @Description: 动态表单
 * @date 2022/2/17 19:22
 */
public interface BpmFormMapper {

    //添加
    Long insert(BpmForm form);

    //更新
    void updateById(BpmForm form);

    //查找
    List<BpmForm> selectList(BpmForm form);

    //批量删除
    void deleteIds(Long[] ids);

    //安全批量删除
    void safeDeleteIds(Long[] ids);

    //通过ID查找
    BpmForm selectById(Long id);

    //安全删除
    @Update("update bpm_form set deleted = 1 where id = #{id}")
    void safeDelete(Long id);


    //删除
    @Delete("delete from bpm_form where id =#{id}")
    void delete(Long id);


    List<BpmForm> selectList();

    List<BpmForm> selectListVO(BpmForm bpmForm);

    List<BpmForm> selectBatchIds(Long[] ids);

    List<BpmForm> getFormPage(BpmFormPageReqVO pageReqVO);

    //PageResult<BpmForm> selectPage(BpmFormPageReqVO pageReqVO);
}
